#ifndef __UART_SEND_H_
#define __UART_SEND_H_

#include "user_cfg.h"


typedef enum {
	UARTY = 0,					//UART1
	UARTZ						//UART2
} uart_dev_t;

typedef struct {
	unsigned char *buf;
	unsigned char len;
} uart_cfg_t;


typedef struct {
	unsigned char len;
	unsigned char send_cnt;
	unsigned char *buf;
	unsigned char buf_size;

} uart_tx_t;

typedef struct {
	unsigned char on_off;
} uart_flag_t;

extern uart_flag_t uart_flag;
extern uart_tx_t tx_buf[2];
extern unsigned char tx_flag[2];


void Uart_Send_Init(uart_dev_t dev, uart_cfg_t *cfg);

void Uart_Send(uart_dev_t dev, unsigned char *buf, unsigned char len);

void Uart_Send_Irq(uart_dev_t dev);

#endif



